package cn.bincker.mycaptcha.basic.properties;

import cn.bincker.mycaptcha.utils.ColorUtils;
import lombok.AllArgsConstructor;
import lombok.Getter;
import lombok.Setter;

import java.awt.*;

@Setter
@Getter
@AllArgsConstructor
public class ShadowProperties {
    private Boolean enabled;
    private Integer size;
    private Integer x;
    private Integer y;
    private Integer blurRadius;
    private Color color;

    public ShadowProperties() {
        this.enabled = false;
    }

    public void setColor(String color) {
        this.color = ColorUtils.decodeColor(color);
    }
}
